package io;

import java.io.*;


public class CopyDemo04 {
    public static void main(String[] args) throws IOException {
        BufferedInputStream bis = new BufferedInputStream(new FileInputStream("d.txt"));
        BufferedOutputStream bos = new BufferedOutputStream(new FileOutputStream("e.txt"));
        int d;
        while ((d=bis.read())!=-1){
            bos.write(d);
        }
        bos.close();
        bis.close();
        System.out.println("读写完成");
    }
}
